package mysql;

import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;



public class CreateConnection {
	private CreateConnection(){
		
	}
	
	private static Connection connection = null;
	
	public static Connection getConnection(){
		String driver = "com.mysql.jdbc.Driver";

		String url = "jdbc:mysql://123.207.241.214/mvc";

		String user = "root";

		String password = "123";
		
		try{
			Class.forName(driver);
			connection = DriverManager.getConnection(url,user,password);
		}catch(ClassNotFoundException e){
			e.printStackTrace();
		}catch (SQLException e) {
			// TODO: handle exception
			e.printStackTrace();
		}
		
		return connection;
	}

}
